Problem Note 52523: The MDYAMPM format does not display values properly when the width is less than 17
The MDYAMPM format does not display values properly when the format width is less than 17. Instead of writing as much of the datetime value as possible, zeros are written in the formatted value instead.
The sample code below illustrates the problem.
data _null_;
a = DATETIME();
put a= MDYAMPM16.0;
run;
a=0/0/0
The documentation states that the width range for the MDYAMPM format is 8-40. However, widths less than 17 do not produce the correct output.
Operating System and Release Information
SAS System | Base SAS | z/OS | 9.2 TS1M0 | 9.4 TS1M0 |
Microsoft® Windows® for 64-Bit Itanium-based Systems | 9.2 TS1M0 | |
Microsoft Windows Server 2003 Datacenter 64-bit Edition | 9.2 TS1M0 | |
Microsoft Windows Server 2003 Enterprise 64-bit Edition | 9.2 TS1M0 | |
Microsoft Windows XP 64-bit Edition | 9.2 TS1M0 | |
Microsoft® Windows® for x64 | 9.2 TS1M0 | 9.4 TS1M0 |
Microsoft Windows Server 2003 Datacenter Edition | 9.2 TS1M0 | |
Microsoft Windows Server 2003 Enterprise Edition | 9.2 TS1M0 | |
Microsoft Windows Server 2003 Standard Edition | 9.2 TS1M0 | |
Microsoft Windows XP Professional | 9.2 TS1M0 | |
Windows Vista | 9.2 TS1M0 | |
Windows Vista for x64 | 9.2 TS1M0 | |
64-bit Enabled AIX | 9.2 TS1M0 | 9.4 TS1M0 |
64-bit Enabled HP-UX | 9.2 TS1M0 | 9.4 TS1M0 |
64-bit Enabled Solaris | 9.2 TS1M0 | 9.4 TS1M0 |
HP-UX IPF | 9.2 TS1M0 | 9.4 TS1M0 |
Linux | 9.2 TS1M0 | 9.4 TS1M0 |
Linux for x64 | 9.2 TS1M0 | 9.4 TS1M0 |
OpenVMS on HP Integrity | 9.2 TS1M0 | 9.4 TS1M0 |
Solaris for x64 | 9.2 TS1M0 | 9.4 TS1M0 |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
Type: | Problem Note |
Priority: | medium |
Topic: | SAS Reference ==> Formats ==> Date and Time
|
Date Modified: | 2014-03-21 14:03:36 |
Date Created: | 2014-03-07 12:36:01 |